package com.yao.sys.entity.dto;


import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.yao.sys.entity.UserEntity;
import com.yao.sys.enums.SexEnum;

import lombok.Data;

/**
* 用户表
*
* @author autoCode
* @version 1.0.0-SNAPSHOT
* @date 2020-03-23
*/
@Data
@TableName("sys_user")
public class UserDto extends UserEntity {


    @TableField(exist = false)
    private String sexDesc;

    @TableField(exist = false)
    private String statusDesc;

    @TableField(exist = false)
    private String accountName;




    public UserDto fill(){
        sexDesc = SexEnum.getDesc(getSex());
        statusDesc = getStatus().getDesc();
        return this;
    }

}